<!DOCTYPE html>
<html>
<#include "../head.html">
<body class="full">
<table class="mc">
    <tr>
        <td class="mc-l">
            <!--左侧导航---{-->
            <div id="navPanelContainer">
                <div class="system-logo cd"></div>
                <!--管理员信息---{-->
                    <#include "../adminInfo.html">
                <!--管理员信息---}-->
                <div class="nav-wrap">
                    <#include "left.html">
                </div>
            </div>
            <!--左侧导航---}-->
        </td>
        <td class="mc-m">
            <div class="navToggle"></div>
        </td>
        <td class="mc-r">
            <!--顶部导航---{-->
            <#include "../topNav.html">
            <!--顶部导航---}-->

            <!--面包屑导航---{-->
            <#assign moduleName="邀请用户">
            <#include "banner.html">
            <!--面包屑导航---}-->

            <!--工具栏--{-->
            <div id="toolbar" class="clearfix">
                <div class="toolbor-module export">
                    <input type="button" onclick="exportxls()" value="导出列表" class="input-button export-btn"/>
                </div> 
            
                <div class="toolbor-module search">
                    <input type="button" value="搜索"  class="input-button" onclick="sousuo();">
                </div>
            
	
				<div class="toolbor-module search">
                    <div class="formTit">状态：</div>
                   <div class="select-box" id="sendFlag">
                        <div class="tag-select">全部</div>
                        <ul class="tag-options">
                           <li data-value="">全  部</li>
                           <li data-value="1">已派送</li>
                           <li data-value="0">未派送</li>
                        </ul>
                    </div>
                </div>
                   
                 <div class="toolbor-module search">
                 <div class="formTit">邀请人：</div>
                    <input type="text" name="showName" id="showName" value="请输入用户名"  class="search-value">
                </div>
                
                <div class="toolbor-module search">
                 <div class="formTit">用户名：</div>
                    <input type="text" name="userName" id="userName" value="请输入用户名"  class="search-value">
                </div>
                
                <div class="toolbor-module search">
                <div class="formTit">注册时间：</div>
                <input class="_search-value" name="startDate" id="startDate" value="" onclick="change_picktime()"/>
                <div class="formTit"> 到 </div>
                <input class="_search-value" name="endDate" id="endDate" value="" id="" onclick="change_picktime()"/>
            	</div>
            </div>
            <!--工具栏--}-->

            <div id="main" class="clearfix">
                <form action="" method="post">
                    <table class="data-list">
                        <tr class="header">
                            <td>ID</td>
                            <td>用户名</td>
                            <td>真实姓名</td>
                            <td>实名状况</td>
                            <td>注册ip地址</td>>
                            <td>邀请人</td>
                            <td>邀请人真实姓名</td>
                            <td>邀请日期</td>
                            <td>状态</td>
                        </tr>
                        <#if list?? && (list?size > 0)>
                            <#list list as item>
                                <tr class="s">
                                    <td>${item.id?c}</td>
                                    <td>${item.inviteeUser.showName!}</td>
                                    <td>${item.inviteeUser.realName!}</td>
                                    <td><#if item.inviteeUser.realStatus==1><font color="green">认证</font><#else><font color="red">未认证</font></#if></td>
                                    <td>${item.inviteeUser.addIp!''}</td>
                                   	<td>${item.user.showName!}</td>
                                    <td>${item.user.realName!''}</td>
                                    <td>${item.createDate}</td>
                                    <#if item.sendFlag==1>
                                    <td style="color:green;">已派送</td>
                                    <#else>
                                    <td>未派送</td>
                                    </#if>
                                </tr>
                            </#list>
                          </#if>
                    </table>
                </form>

                <!--底部工具栏--{-->
                <div id="bottomToolbar" class="clearfix">
                    <div class="other-tool">
                        <dl class="refresh-data">
                            <dt class="refresh-data-icon"></dt>
                            <dd><a href="javascript:void(0);" class="refresh-page">刷新数据</a></dd>
                        </dl>
                    </div>

                    <!--翻页系统--{-->
                    <div class="container s_formPage">
                        <#import "../../common/page.html" as pager>
                            <@pager.pagination page=page url="${pageUrl}" map=param style="style1" />
                    </div>
                    <!--翻页系统--}-->
                </div>
                <!--底部工具栏--}-->

                <script>
                    var urls = '?search=true';
                    function sousuo(){
                        var sou = "";
                        var showName = $("#showName").val();
                        if (showName!=null&&showName!=""&&showName!="undefine"&&showName!="请输入用户名"){
                            sou += "&showName="+showName;
                        }
                        var userName = $("#userName").val();
                        if (userName!=null&&userName!=""&&userName!="undefine"&&userName!="请输入用户名"){
                            sou += "&userName="+userName;
                        }
                        var sendFlag = $("#sendFlag").find(".open-selected").attr("data-value");
                        if(sendFlag!=null&&sendFlag!=""&&sendFlag!="undefine"){
                        	sou += "&sendFlag="+sendFlag;
                        }
                        var startDate = $("#startDate").val();
                       	var endDate = $("#endDate").val();
                        if (startDate!=null){
                            sou += "&startDate="+startDate;
                        }
                        if (endDate!=null){
                            sou += "&endDate="+endDate;
                        }
                        var url=urls+sou
                        location.href=url;
                    }
                     function exportxls(){
                       var xurl="inviteUser.html?type=export"
                       var sou = "";
                       var showName = $("#showName").val();
                       if (showName!=null&&showName!=""&&showName!="undefine"&&showName!="请输入用户名"){
                           sou += "&showName="+showName;
                       }
                       var userName = $("#userName").val();
                       if (userName!=null&&userName!=""&&userName!="undefine"&&userName!="请输入用户名"){
                           sou += "&userName="+userName;
                       }
                       var sendFlag = $("#sendFlag").find(".open-selected").attr("data-value");
                       if(sendFlag!=null&&sendFlag!=""&&sendFlag!="undefine"){
                        sou += "&sendFlag="+sendFlag;
                       }
                       var startDate = $("#startDate").val();
                        var endDate = $("#endDate").val();
                       if (startDate!=null){
                           sou += "&startDate="+startDate;
                       }
                       if (endDate!=null){
                           sou += "&endDate="+endDate;
                       }
                       var url=xurl+sou
                       location.href=url;
                   }
                </script>
            </div>

        </td>
    </tr>
    <tr>
        <!--尾部--{-->
        <td colspan="3" class="mc-b"><#include "../foot.html"></td>
        <!--尾部--}-->
    </tr>
</table>
</body>
</html>
<#include "../jsPage.html">
